package com.kaifamiao.month04.day13;

public class Demo03 {

    public static void main(String[] args) {
        checkRange(12);
    }

    public static void checkRange(int num) {
        if(num < 0 || num > 10) {
            throw new ArrayIndexOutOfBoundsException(num); // 抛异常
        }
        System.out.println("true");
    }
}
